home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / std / c / 128 < prev    next >
Internet Message Format  |  1996-08-06  |  1KB

  1. Path: zetnet.co.uk!demon!polo!john
  2. From: john@polo.demon.co.uk (John Winters)
  3. Newsgroups: comp.std.c
  4. Subject: Re: ... char * * promotion to char const * const * ...
  5. Date: Wed, 17 Jan 1996 15:09:47 GMT
  6. Organization: Wallingford
  7. Message-ID: <DLBzGB.J60@polo.demon.co.uk>
  8. References: <4dgj8q$qin@unix.sri.com> <KANZE.96Jan17121659@slsvewt.lts.sel.alcatel.de>
  9. X-NNTP-Posting-Host: polo.demon.co.uk
  10.  
  11. In article <KANZE.96Jan17121659@slsvewt.lts.sel.alcatel.de>,
  12. James Kanze US/ESC 60/3/141 #40763 <kanze@lts.sel.alcatel.de> wrote:
  13. [snip]
  14. >
  15. >Originally, the C standard was going to allow this; in fact, it was
  16. >going to allow all casts which added const anywhere in the type.  Then
  17. >someone pointed out that the conversion 'char ** -> char *const *' was
  18. >unsafe.  As a result, the wording was changed to only allow adding the
  19. >const at the top level.
  20.  
  21. Interesting.  Could you enlighten us (well, me anyway) as to *why* it
  22. is unsafe.  I don't find it immediately obvious.
  23.  
  24. John
  25. -- 
  26. John Winters.  Wallingford, Oxon, England.
  27.